<?php
include_once 'header.php';
$navbar='categorylist.php';
$mainsite= 'main.php';
if(isset($_GET['action'])){ 
    $mainsite=$_GET['action'];
    $mainsite=$mainsite.'.php';
}

?>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Welcome to e-agora!</title>
    </head>
    <body>
        <div class="top_container" style="height:125px;width:100%;margin:0;padding:0;">
            <div class="title" style="height:80%;width:100%;background-color:#00BFFF;">
                <h1><a href="./index.php">e-agora.gr</a></h1>
            </div>

            <div class="search" style="height:20%;width:100%;background-color: #696969;padding-left:5px;">
            <?php include_once 'searchfield.php';
            ?>
            
            </div>
        </div>
            <div class="left_sidebar" style="width:160px;height:100%;float:left;background-color:#FF8C00;margin: 0px 20px 10px 0px;padding: 0px 10px;">
            <?php 
            include_once $navbar; 
            ?>

            </div>
            
            <div class="right_sidebar" style="width:160px;height:100%; float:right;background-color:#FF8C00;margin-left: 20px;padding: 0px 10px;">
            <?php
            include_once 'userstatus.php';
            ?>
            </div>
            
            <div class="site" style="background-color: #cccccc ;height: 100%;margin:auto;padding: 5px 20px;">
               <br />
                 <?php
                     include_once $mainsite;
                ?>
             </div>
    </body>
</html>
